#include "widget.h"
#include "ui_widget.h"
#include <QPushButton>
#include <QDebug>
Widget::Widget(QWidget *parent)
    : QWidget(parent)
    , ui(new Ui::Widget)
{
    ui->setupUi(this);
    QPushButton* btn = new QPushButton(this);
    btn->setText("按钮");
    btn->move(300,300);
    connect(btn,&QPushButton::clicked,this,[=]()
    {
        btn->move(400,400);
    });
}
Widget::~Widget()
{
    delete ui;
}

